package button

import "learngo/delegate/label"
import "fmt"

type Button struct {
	Label label.Label
}

func (button Button) CreateButton(x,y int, text string) *Button{
	return &Button {
		Label: label.Label{
			W: label.Widget{X:x,Y:y},
			T: text,
		},
	}
}
//overrride
func (button Button) Draw()  {
	fmt.Printf("[%p] - Button.draw(%q)\n", &button, button.Label.T)
}

func (button Button) Click()  {
	fmt.Printf("[%p] - Button.Click()\n", &button)
}